package body v8.Class_Script is
   function Create
     (source      : v8.Class_String.Pointer;
      origin      : access v8.Class_Script_Origin.Script_Origin := null;
      pre_data    : v8.Class_Script_Data.Pointer := null;
      script_data : v8.Class_String.Pointer := null
     ) return Pointer
   is
      function Invoke
        (source      : v8.Class_String.Pointer := Create.source;
         origin      : access v8.Class_Script_Origin.Script_Origin := Create.origin;
         pre_data    : v8.Class_Script_Data.Pointer := Create.pre_data;
         script_data : v8.Class_String.Pointer := Create.script_data
        ) return Pointer;
      pragma Import (CPP, Invoke, "_ZN2v86Script3NewENS_6HandleINS_6StringEEEPNS_12ScriptOriginEPNS_10ScriptDataES3_");
   begin
      return Invoke;
   end Create;
   pragma Inline (Create);

   function Create
     (source    : v8.Class_String.Pointer;
      filename  : v8.Class_Value.Pointer
     ) return Pointer
   is
      function Invoke
        (source    : v8.Class_String.Pointer := Create.source;
         file_name : v8.Class_Value.Pointer := Create.filename
        ) return Pointer;
      pragma Import (CPP, Invoke, "_ZN2v86Script3NewENS_6HandleINS_6StringEEENS1_INS_5ValueEEE");
   begin
      return Invoke;
   end Create;
   pragma Inline (Create);

   function Compile
     (source      : v8.Class_String.Pointer;
      origin      : access v8.Class_Script_Origin.Script_Origin := null;
      pre_data    : v8.Class_Script_Data.Pointer := null;
      script_data : v8.Class_String.Pointer := null
     ) return Pointer
   is
      function Invoke
        (source      : v8.Class_String.Pointer := Compile.source;
         origin      : access v8.Class_Script_Origin.Script_Origin := Compile.origin;
         pre_data    : v8.Class_Script_Data.Pointer := Compile.pre_data;
         script_data : v8.Class_String.Pointer := Compile.script_data
        ) return Pointer;
      pragma Import (CPP, Invoke, "_ZN2v86Script7CompileENS_6HandleINS_6StringEEEPNS_12ScriptOriginEPNS_10ScriptDataES3_");
   begin
      return Invoke;
   end Compile;
   pragma Inline (Compile);

   function Compile
     (source    : v8.Class_String.Pointer;
      filename  : v8.Class_Value.Pointer;
      script_data : v8.Class_String.Pointer := null
     ) return Pointer
   is
      function Invoke
        (source    : v8.Class_String.Pointer := Compile.source;
         file_name : v8.Class_Value.Pointer := Compile.filename;
         script_data : v8.Class_String.Pointer := Compile.script_data
        ) return Pointer;
      pragma Import (CPP, Invoke, "_ZN2v86Script7CompileENS_6HandleINS_6StringEEENS1_INS_5ValueEEES3_");
   begin
      return Invoke;
   end Compile;
   pragma Inline (Compile);

end v8.Class_Script;
